package com.histone.lib_download.downloader;

/**
 * @author robin
 * @version v1.0 [2020/6/11]
 */
public class ThreadInfo {
    public int id;
    public String url;
    public long thread_start;
    public long thread_end;
    public long finished;

    public ThreadInfo() {
    }

    /**
     * @param id           线程ID
     * @param url          下载路径
     * @param thread_start 开始下载的位置
     * @param thread_end   结束下载的位置
     * @param finished     完成下载的位置
     */
    public ThreadInfo(int id, String url, long thread_start, long thread_end, long finished) {
        this.id = id;
        this.url = url;
        this.thread_start = thread_start;
        this.thread_end = thread_end;
        this.finished = finished;
    }

    @Override
    public String toString() {
        return "ThreadInfo{" +
                "id=" + id +
                ", url='" + url + '\'' +
                ", thread_start=" + thread_start +
                ", thread_end=" + thread_end +
                ", finished=" + finished +
                '}';
    }
}
